package com.sxjh.entity.param;

import com.baomidou.mybatisplus.annotation.TableField;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.math.BigDecimal;
import java.time.LocalDate;
import java.time.LocalDateTime;

@Data
public class ChemicalYaResult {

    @ApiModelProperty("序号")
    private Integer serialNumber;

    @ApiModelProperty("合同号")
    private String contractNo;

    @ApiModelProperty("合同号")
    private String companyName;

    @ApiModelProperty("车牌号")
    private String  carNumber ;

    @ApiModelProperty("原发数量")
    private BigDecimal netWeight;

    @ApiModelProperty("实收数量")
    private BigDecimal weighbridgeWeight;

    @ApiModelProperty("结算单价")
    private BigDecimal settlementPrice;

    @ApiModelProperty("出场时间")
    private LocalDate factoryOutTime;

    @ApiModelProperty("每吨运费")
    @TableField(exist = false)
    private BigDecimal freight;

    @ApiModelProperty("金额")
    @TableField(exist = false)
    private BigDecimal money;

    @ApiModelProperty("磅差")
    private BigDecimal tunnage;

    @TableField(exist = false)
    @ApiModelProperty("磅差扣款")
    private BigDecimal withhold;

    @TableField(exist = false)
    @ApiModelProperty("运费")
    private BigDecimal assemble_money;

    @TableField(exist = false)
    @ApiModelProperty("总金额")
    private BigDecimal moneySum;

    public BigDecimal getNetWeight() {
        if("".equals(netWeight)||netWeight==null){
            return new BigDecimal(0);//去除该属性的前后空格并进行非空非null判断
        }
        return netWeight;
    }

    public BigDecimal getWeighbridgeWeight() {
        if("".equals(weighbridgeWeight)||weighbridgeWeight==null){
            return new BigDecimal(0);//去除该属性的前后空格并进行非空非null判断
        }
        return weighbridgeWeight;
    }

    public BigDecimal getSettlementPrice() {
        if("".equals(settlementPrice)||settlementPrice==null){
            return new BigDecimal(0);//去除该属性的前后空格并进行非空非null判断
        }
        return settlementPrice;
    }

    public BigDecimal getFreight() {
        if("".equals(freight)||freight==null){
            return new BigDecimal(0);//去除该属性的前后空格并进行非空非null判断
        }
        return freight;
    }

    public BigDecimal getMoney() {
        if("".equals(money)||money==null){
            return new BigDecimal(0);//去除该属性的前后空格并进行非空非null判断
        }
        return money;
    }

    public BigDecimal getTunnage() {
        if("".equals(tunnage)||tunnage==null){
            return new BigDecimal(0);//去除该属性的前后空格并进行非空非null判断
        }
        return tunnage;
    }

    public BigDecimal getWithhold() {
        if("".equals(withhold)||withhold==null){
            return new BigDecimal(0);//去除该属性的前后空格并进行非空非null判断
        }
        return withhold;
    }

    public BigDecimal getMoneySum() {
        if("".equals(moneySum)||moneySum==null){
            return new BigDecimal(0);//去除该属性的前后空格并进行非空非null判断
        }
        return moneySum;
    }

    public BigDecimal getAssemble_money() {
        if("".equals(assemble_money)||assemble_money==null){
            return new BigDecimal(0);//去除该属性的前后空格并进行非空非null判断
        }
        return assemble_money;
    }
}